<%@taglib uri="/struts-tags" prefix="s" %>
<%
	Object o = session.getAttribute("cardNo");
	if (o == null) {
%>
<script>
	alert("Can't access this page like this!");
	window.location.href = "index.html";
</script>
<%
	}
%>
<head>
<script src="javascript/javascript.js"></script>
</head>
<body onload="viewHistory()">
<input type="hidden" name="txtProcess" value="viewHistory" />
	<div style="width: 100%; height: 100%;">
		<div style="width: 100%; height: 80%; padding-top: 10px;">
			<center>
				<table  border=1px style="width: 99%; border: solid green;">
					<thead style=" border: 1px solid green;">
						<tr style=" border: 1px solid green;">
							<th style="text-align: center;">ATM</th>
							<th style="text-align: center;">Type</th>
							<th style="text-align: center;">Date</th>
							<th style="text-align: center;">Amount</th>
							<th style="text-align: center;">To</th>
						</tr>
					</thead>
					<tbody style=" border: 1px solid green;">
					<s:iterator value="viewList" id="view">
						<tr>
							<td style="text-align: center;"><s:property value="#view.atmAddress" /></td>
							<td style="text-align: center;"><s:property value="#view.typeLog" /></td>
							<td style="text-align: center;"><s:property value="#view.date" /></td>
							<td style="text-align: center;"><s:property value="#view.amount" /></td>
							<td style="text-align: center;"><s:property value="#view.to" /></td>
						</tr>
					</s:iterator>
					</tbody>
				</table>
			</center>
		</div>
		<input type="hidden" name="currentPage" value='<s:property value="currentPage" />' />
		<div style="width: 100%; height: 20%;">
			<div
				style="width: 50px; height: 25px; border: 1px solid green; float: left; position: relative; left: 10px; top: -25px; color: white; background-color: green;">Pre <s:property value="currentPage" />/<s:property value="maxPage" /></div>
			<div
				style="width: 70px; height: 25px; border: 1px solid green; float: right; position: relative; left: -10px; top: -25px; color: white; background-color: green;"><s:property value="currentPage" />/<s:property value="maxPage" /> Next</div>
				<center>Press enter to print result</center>
		</div>
	</div>
</body>